package com.xh.bussiness.resource.dao;

import com.xh.bussiness.resource.bean.request.MaterialRequest;
import com.xh.bussiness.resource.model.Material;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xh.bussiness.tiku.bean.request.QuestionQueryRequest;
import com.xh.core.bean.XhPage;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 资料 Mapper 接口
 * </p>
 *
 * @author JQM
 * @since 2019-08-27
 */
public interface MaterialMapper extends BaseMapper<Material> {
    XhPage<Material> queryByPage(@Param("page")XhPage page, @Param("bean") MaterialRequest bean);

    List<Map<String, Object>> queryCountByType(@Param("bean") MaterialRequest bean);

    List<Material> queryMaterialByChapterId(@Param("chapterId") String chapterId);

    List<Material> queryUserPrivateMaterial(@Param("bean") MaterialRequest bean);

    Material queryMaterialById(@Param("id") String id);
}
